<!--<nz-spin [nzSpinning]="isSpinning">
  <form nz-form [formGroup]="validateForm" (ngSubmit)="submitForm($event,validateForm.value)">-->
    <nz-spin [nzTip]="'正在提交数据...'" [nzSpinning]="isSpinning">
      <div class="carouselAdd">
        <form nz-form [formGroup]="validateForm" class="login-form">
          <!--所属端(电脑、手机)-->
          <div nz-form-item nz-row>
            <div nz-form-label nz-col [nzSpan]="8">
              <label>所属类型</label>
            </div>
            <div nz-form-control nz-col [nzSpan]="14">
              <div nz-form-control nz-col [nzSm]="12" [nzXs]="12">
                <!-- <nz-input formControlName="discription"  [(ngModel)]="bean.discription"></nz-input> -->
                <nz-select formControlName="discription" nzAllowClear [nzPlaceHolder]="'请选择'" [(ngModel)]="advertisementBean.discription" [nzShowSearch]="true"
                           name="discription">
                  <nz-option *ngFor=" let dis  of discriptionList" [nzLabel]="dis.label" [nzValue]="dis.label" [nzDisabled]="false">
                  </nz-option>
                </nz-select>
              </div>
              <div nz-form-explain *ngIf="validateForm.controls.discription.dirty&&validateForm.controls.discription.hasError('required')">所属端不能为空!</div>
            </div>
          </div>
          <!--操作类型-->
          <div nz-form-item nz-row>
            <div nz-form-label nz-col [nzSpan]="8">
              <label>操作类型</label>
            </div>
            <div nz-form-control nz-col [nzSpan]="14">
              <div nz-form-control nz-col [nzSm]="12" [nzXs]="12">
                <!-- <nz-input formControlName="discription"  [(ngModel)]="bean.discription"></nz-input> -->
                <nz-select  formControlName="operateType" nzAllowClear [nzPlaceHolder]="'请选择'" [(ngModel)]="advertisementBean.operateType" [nzShowSearch]="true"
                            name="operateType">
                    <nz-option *ngFor=" let type  of advertisementTypeList" [nzLabel]="type.label" [nzValue]="type.value" [nzDisabled]="false"></nz-option>
                </nz-select>
              </div>
              <div nz-form-explain *ngIf="validateForm.controls.discription.dirty&&validateForm.controls.discription.hasError('required')">操作类型不能为空!</div>
            </div>
          </div>
          <!--链接地址-->
          <div nz-form-item nz-row *ngIf="advertisementBean.operateType=='2'  || advertisementBean.operateType=='4'"  >
            <div nz-form-label nz-col [nzSpan]="8">
              <label>链接地址</label>
            </div>
            <div  nz-col [nzSm]="8" [nzXs]="8">
              <nz-input [nzSize]="'large'" [nzId]="'linkUrl'" [(ngModel)]="advertisementBean.linkUrl"  val name="linkUrl" formControlName="linkUrl" ></nz-input>
            </div>
          </div>
          <!--资讯详情-->
          <div nz-form-item nz-row *ngIf="advertisementBean.operateType=='3'">
            <div nz-form-label nz-col [nzSpan]="8">
              <label>资讯详情</label>
            </div>
            <div nz-form-control nz-col [nzSpan]="14">
              <div nz-form-control nz-col [nzSm]="12" [nzXs]="12">
                <nz-select  formControlName="infoId" nzAllowClear [nzPlaceHolder]="'请选择'" [(ngModel)]="advertisementBean.infoId" [nzShowSearch]="true"
                            name="infoId">
                  <nz-option [nzLabel]="advertisementBean.infoTitle" [nzValue]="advertisementBean.infoId" aria-selected="true"></nz-option>
                  <nz-option *ngFor=" let info  of infoList" [nzLabel]="info.title" [nzValue]="info.id" [nzDisabled]="false" ></nz-option>
                </nz-select>
              </div>
              <div nz-form-explain *ngIf="validateForm.controls.discription.dirty&&validateForm.controls.discription.hasError('required')">操作类型不能为空!</div>
            </div>
          </div>
          <!--上传图片功能-->
          <div nz-form-item nz-row>
            <div nz-form-label nz-col [nzSpan]="8">
              <label>上传图片</label>
            </div>
            <div nz-form-control nz-col [nzSpan]="16">
              <div nz-form-control nz-col [nzSm]="16" [nzXs]="16">
                <nz-upload nzAction="{{config.IP+config.API.upload}}" nzListType="picture-card" [nzShowButton]="fileList.length < 1" [(nzFileList)]="fileList"
                           [nzPreview]="handlePreview" [nzRemove]="nzRemoveFile" (nzChange)="handleChange($event)">
                  <i class="anticon anticon-plus"></i>
                  <div class="ant-upload-text">上传</div>
                </nz-upload>
                <nz-modal [nzVisible]="previewVisible" [nzContent]="modalContent" [nzFooter]="null" (nzOnCancel)="previewVisible=false">
                  <ng-template #modalContent>
                    <img [src]="previewImage" [ngStyle]="{ 'width': '100%' }" />
                  </ng-template>
                </nz-modal>
              </div>
            </div>
          </div>
          <!--按钮-->
          <div nz-form-item nz-row>
            <div nz-form-control nz-col [nzOffset]="'9'" [nzSpan]="3">
              <button nz-button class="login-form-button" [nzType]="'primary'" [nzSize]="'large'" (click)="submitForm()">修改</button>
            </div>
            <div nz-form-control nz-col [nzSpan]="2">
              <button nz-button class="login-form-button" [nzType]="'primary'" [nzSize]="'large'" (click)="quit()">取消</button>
            </div>
          </div>
        </form>
      </div>
    </nz-spin>
